package name.wilbur.course.db.bigone.model;

public class BaseDBModel implements IDBEntity {
	protected int pk;
	
	public BaseDBModel() {
	}
	
	public BaseDBModel(int pk) {
		this.pk = pk;
	}
	
	public int getPk() {
		return pk;
	}

	public void setPk(int pk) {
		this.pk = pk;
	}

	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result + pk;
		return result;
	}

	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		BaseDBModel other = (BaseDBModel) obj;
		if (pk != other.pk)
			return false;
		return true;
	}

	
}
